
#region Using Statements

    using System;
    using System.Collections;
    using System.Diagnostics;
    using System.IO;
    using System.Collections.ObjectModel;
    using System.Collections.Generic;
    using System.Linq;

    using System.Xml.Linq;
    using Microsoft.Xna.Framework;
    using Microsoft.Xna.Framework.Graphics;
    using Microsoft.Xna.Framework.Content.Pipeline;
    using Microsoft.Xna.Framework.Content.Pipeline.Graphics;

#endregion

namespace HumanElement.Xna.ContentPipeline
{
    using TImport = System.Collections.Generic.IEnumerable<System.Xml.Linq.XElement>;

    /// <summary>
    /// This class will be instantiated by the XNA Framework Content Pipeline
    /// to import a file from disk into the specified type, TImport.
    /// 
    /// This should be part of a Content Pipeline Extension Library project.
    /// </summary>
    [Serializable]
    public class SurfaceContent : ContentItem
    {
        protected ContentProcessorContext context;

        public SurfaceContent(XElement x, ContentProcessorContext context)
        {
            
        }

        /// <summary>
        /// Gets or sets the effects.
        /// </summary>
        /// <value>The effects.</value>
        public EffectContent[] Effects
        {
            get; set;
        }

        /// <summary>
        /// Gets or sets the effect textures.
        /// </summary>
        /// <value>The effect textures.</value>
        public EffectMaterialContent[] EffectTextures
        {
            get; set;
        }

        /// <summary>
        /// Gets or sets the textures.
        /// </summary>
        /// <value>The textures.</value>
        public Texture2DContent[] Textures
        {
            get; set;
        }

        /// <summary>
        /// Gets or sets the passes.
        /// </summary>
        /// <value>The passes.</value>
        public EffectPass[] Passes
        {
            get; set;
        }
        
        /// <summary>
        /// Gets or sets the source.
        /// </summary>
        /// <value>The source.</value>
        public XElement Source
        {
            get; set;
        }


        /// <summary>
        /// Loads from X element.
        /// </summary>
        /// <param name="xml">The XML.</param>
        /// <param name="context">The context.</param>
        /// <returns></returns>
        protected virtual bool LoadFromXElement(XElement xml, ContentProcessorContext context)
        {
#if(DEBUG)
            if (!Debugger.IsAttached)
                Debugger.Launch();

            Debugger.Break();
#endif
            var res = false;

            // TODO: put xml reader here..  

            return res;
        }
    }      
}
